<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>老干部信息系统-注销登陆</title>

<!-- Load the Google AJAX API Loader -->
<script type="text/javascript" src="http://www.google.com/jsapi"></script>

<!-- Load the Google Friend Connect javascript library. -->
<script type="text/javascript">
	google.load('friendconnect', '0.8');
	</script>

<!-- Initialize the Google Friend Connect OpenSocial API. -->
<script type="text/javascript">
	
	function initfc(times) { };

      function onFriendConnectInitialized(st) {
        if (!window.friendconnect_times_loaded) {
          window.friendconnect_times_loaded = 1;
        } else {
          window.friendconnect_times_loaded++;
        }
        initfc(window.friendconnect_times_loaded);
      };
          
      function onAjaxLoaded() {
        google.friendconnect.container.setParentUrl('/');
        google.friendconnect.container.loadOpenSocialApi({
          site: '15387073527982291758',
          onload: onFriendConnectInitialized
        });
      };

	google.setOnLoadCallback(onAjaxLoaded);

</script>
</head>
<body>

<p>注销登陆进行中.......</p>

<!-- 第二次请求的时候 -->

<script type="text/javascript"> 
  window.initfc = function(times) {
    if (times <= 1) {
      google.friendconnect.requestSignOut();
      //这个是防止注销失败，再次尝试！
      window.setTimeout(function() {
        window.top.location.href = "/freemarker?action=logout";
      }, 3000);
    } else {
      window.top.location.href = "/";      
    }
  };
</script>

</body>
</html>